/*
 * Copyright (c) 2016 咖枯 <kaku201313@163.com | 3772304@qq.com>
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 */
package com.lixh.virtual.api;

public class ApiConstants {

    public static final String BASE_URL = "http://183.131.85.75:803";
    public static final String UPINGMEDIASERVICE_URL = "http://upingmediaservice.cxtinfo.com";
    public static final String[] HOSTS = new String[]{
            "http://xfcd.ctfs.ftn.qq.com/",
            "http://xfxa.ctfs.ftn.qq.com/",
            "http://xa.ctfs.ftn.qq.com/",
            "http://sh.ctfs.ftn.qq.com/",
            "http://xfsh.ctfs.ftn.qq.com/",
            "http://hz.ftn.qq.com/",
            "http://tj.ctfs.ftn.qq.com/",
            "http://cd.ctfs.ftn.qq.com/",
            "http://sz.ctfs.ftn.qq.com/",
            "http://xfcd.ctfs.ftn.11.com/",
            "http://sh.btfs.ftn.qq.com/",
            "http://xg.ctfs.ftn.qq.com/",
            "http://xa.btfs.ftn.qq.com/",
            "http://szmail.tfs.ftn.qq.com/",
            "http://xflx.szbtfs.ftn.qq.com/",
            "http://xflx.hz.ftn.qq.com/",
            "http://xflx.store.cd.qq.com/",
            "http://xflx.sz.ftn.qq.com/",
            "http://xflx.xa.ftn.qq.com/",
            "http://xflx.shbtfs.ftn.qq.com/",
            "http://xflx.sh.ftn.qq.com/",
            "http://xflxsrc.store.qq.com/",
            "http://xflx.cdbtfs.ftn.qq.com/",
            "http://xflx.cd.ftn.qq.com/",
            "http://xflx.xabtfs.ftn.qq.com/",
            "http://xflx.tjctfs.ftn.qq.com/",
            "http://xflx.tjbtfs.ftn.qq.com/",
            "http://xflx.szmail.ftn.qq.com/",
            "http://xflx.xatfs.ftn.qq.com/",
            "http://xflx.store.sh.qq.com/"
    };

    public static String getCxtInfoUrl(String action, String host) {
        return host + "ftn_handler/" + action + "?compressed=0&dtype=1&fname=m.mkv";
    }

    /**
     * 获取对应的host
     *
     * @param hostType host类型
     * @return host
     */
    public static String getHost(int hostType) {
        String host;
        switch (hostType) {
            default:
                host = BASE_URL;
                break;
        }
        return host;
    }
}
